import Vue from 'vue'
import App from './App.vue'
import { registerMicroApps, start, setDefaultMountApp} from 'qiankun';
import rss from "./rss";

Vue.config.productionTip = false
new Vue({
  render: h => h(App)
}).$mount('#app')


registerMicroApps([
  {
    name: 'app-nav', // app name registered
    entry: '//localhost:7001',
    container: '#app-nav',
    activeRule: '/index',
    props: {
      rss: rss
    }
  },
  {
    name: 'app-article',
    entry: '//localhost:7002',
    container: '#app-article',
    activeRule: '/index',
    props: {
      rss: rss
    }
  },
], {
  beforeLoad: (app) => console.log('before load', app.name),
  beforeMount: [(app) => console.log('before mount', app.name)],
},);
setDefaultMountApp('/index')
start({singular: false});
